<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script type="text/javascript" th:src="@{/js/baiduhm.js}" ></script>


</head>
<body>
<div th:fragment="event_menu">
    <div class="wrap clearfloat">
        <div class="logo">
            <a th:href="@{/m/event(id=${eventId})}" style="font-size: 18px;letter-spacing: 1px;font-weight: bold;color: #b68036;" >[[ ${eventExhibition.name}]]</a>
        </div>
        <div id="nav">
            <ul class="clearfloat">
                <li th:each="eventExhibitionSectionTemp,index:${eventExhibitionSectionTemps}" th:class="${eventExhibitionSectionTemp.id == sectionId}? 'active' : ''">
                    <a th:href="@{/m/event/page(id=${eventId},sectionId=${eventExhibitionSectionTemp.id})}">[[ ${eventExhibitionSectionTemp.name} ]]</a>
                </li>
            </ul>
        </div>

        <div class="topPhone clearfloat">

        </div>
    </div>
    <script>
        document.addEventListener('DOMContentLoaded', function() {
            // 获取 a 标签
            const link = document.querySelector('.logo a');
            // 获取 a 标签内的文本内容
            const text = link.textContent;
            if (text.length > 14) {
                // 如果文本长度超过 10，截取前 10 个字符并添加省略号
                link.textContent = text.slice(0, 14) + '...';
            }
        });
    </script>
</div>



</body>
</html>
